combit List & Label 29 - .NET Help
In This Topic
    Join and Convert Preview Files
    In This Topic

    The preview format can be used as the output format if, for example, multiple reports should be joined to one or if archiving the output in the form of a PDF is desired in addition to the direct output. The following example shows some options of the PreviewFile class.

    // Open preview files, first file/coversheet with write access
    PreviewFile cover = new PreviewFile(@"<Path>\frontpage.ll", false);
    PreviewFile report = new PreviewFile(@"<Path>\report.ll", true);
    
    // Append report to first file/coversheet
    cover.Append(report);
    
    // Print complete report
    cover.Print();
    
    // Convert report to PDF
    cover.ConvertTo(@"<Path>\report.pdf");
    
    // Release preview files
    report.Dispose();
    cover.Dispose();
    
    ' Open preview files, first file/coversheet with write access
    Dim cover As New PreviewFile("<Path>\frontpage.ll", False)
    Dim report As New PreviewFile("<Path>\report.ll", True)
    
    ' Append report to first file/coversheet
    cover.Append(report)
    
    ' Print complete report
    cover.Print()
    
    ' Convert report to PDF
    cover.ConvertTo("<Path>\report.pdf")
    
    ' Release preview files
    report.Dispose()
    cover.Dispose()